<?php /* Smarty version 2.6.14, created on 2012-11-11 01:41:13
         compiled from profile_photos_file.tpl */
?><?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'array_search', 'profile_photos_file.tpl', 21, false),array('modifier', 'count', 'profile_photos_file.tpl', 22, false),array('modifier', 'replace', 'profile_photos_file.tpl', 69, false),array('modifier', 'escape', 'profile_photos_file.tpl', 83, false),array('modifier', 'default', 'profile_photos_file.tpl', 234, false),array('function', 'math', 'profile_photos_file.tpl', 22, false),)), $this);
?><?php
SELanguage::_preload_multi(1205,1207,1000146,1000147,1216,1217,1218,1212,1219,1220,1221,1222,1223,1224,1225,589,1226,1227,39,1213,1214,1215,1228,155,175,182,183,184,185,187,784,787,829,830,831,832,833,834,835,854,856,891,1025,1026,1032,1034,1071);
SELanguage::load();
?><?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'header.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<script type="text/javascript" src="./include/js/album_ajax_mod.js"></script>      

<div style='width: 532px; margin-left: auto; margin-right: auto;'>

<div class='page_header'>
  <?php echo sprintf(SELanguage::_get(1205), $this->_tpl_vars['url']->url_create('profile',$this->_tpl_vars['page_owner']->user_info['user_username']), $this->_tpl_vars['page_owner']->user_displayname); ?>
</div>


<script type="text/javascript">

</script>




<?php $this->assign('current_index', ((is_array($_tmp=($this->_tpl_vars['media_info']['type']).($this->_tpl_vars['media_info']['media_id']))) ? $this->_run_mod_handler('array_search', true, $_tmp, $this->_tpl_vars['media_keys']) : array_search($_tmp, $this->_tpl_vars['media_keys']))); 
 ob_start(); 
 if ($this->_tpl_vars['current_index'] == 0): 
 echo smarty_function_math(array('equation' => "x-1",'x' => count($this->_tpl_vars['media'])), $this);
 else: 
 echo smarty_function_math(array('equation' => "x-1",'x' => $this->_tpl_vars['current_index']), $this);
 endif; 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('previous_index', ob_get_contents());ob_end_clean(); 
 ob_start(); 
 if ($this->_tpl_vars['current_index']+1 == count($this->_tpl_vars['media'])): ?>0<?php else: 
 echo smarty_function_math(array('equation' => "x+1",'x' => $this->_tpl_vars['current_index']), $this);
 endif; 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('next_index', ob_get_contents());ob_end_clean(); 
 ob_start(); 
 echo smarty_function_math(array('equation' => "x+1",'x' => $this->_tpl_vars['current_index']), $this);
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('current_num', ob_get_contents());ob_end_clean(); ?>
 
<br>

<div style='margin-bottom: 6px;'>
  <table cellpadding='0' cellspacing='0' width='100%'>
  <tr>
  <td id="current_num">
    <?php echo sprintf(SELanguage::_get(1207), $this->_tpl_vars['current_num'], count($this->_tpl_vars['media']), "profile_photos.php?user=".($this->_tpl_vars['page_owner']->user_info['user_username']), $this->_tpl_vars['page_owner']->user_displayname_short, $this->_tpl_vars['url']->url_create('profile',$this->_tpl_vars['page_owner']->user_info['user_username'])); ?>
  </td>
  <td style='text-align: right;'>
    <?php ob_start(); 
 echo $this->_tpl_vars['media_keys'][$this->_tpl_vars['previous_index']]; 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('prev_media_id', ob_get_contents());ob_end_clean(); ?>
    <a id="last" href="javascript:void(0);" onclick="nextpic(0,<?php echo $this->_tpl_vars['media'][$this->_tpl_vars['prev_media_id']]['media_id']; ?>
,'<?php echo $this->_tpl_vars['page_owner']->user_info['user_username']; ?>
',true);"><?php echo SELanguage::_get(1000146); ?></a>
    
    &nbsp;&nbsp;&nbsp;
    <?php ob_start(); 
 echo $this->_tpl_vars['media_keys'][$this->_tpl_vars['next_index']]; 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('next_media_id', ob_get_contents());ob_end_clean(); ?>
    <a id="next" href="javascript:void(0);" onclick="nextpic(0,<?php echo $this->_tpl_vars['media'][$this->_tpl_vars['next_media_id']]['media_id']; ?>
,'<?php echo $this->_tpl_vars['page_owner']->user_info['user_username']; ?>
',true);"><?php echo SELanguage::_get(1000147); ?></a>
    
  </td>
  </tr>
  </table>
</div>



<div class='media'><div  id='loading' style='height:32px; z-index:1000; text-align:center; margin-bottom:-10px; position:absolute; width:500px; display:none'><img src='./images/icons/loading2.gif' border='0'></div>
  <table cellpadding='0' cellspacing='0' align='center'>
  <tr>
  <td style='text-align: center;'>

        <div id='media_photo_div' align='left' class='media_photo_div' style='width:<?php echo $this->_tpl_vars['media_info']['media_width']; ?>
px;height:<?php echo $this->_tpl_vars['media_info']['media_height']; ?>
px;'>

            <div id='photo_div_<?php echo $this->_tpl_vars['media_info']['media_id']; ?>
'  style='position:absolute; opacity: 1;'>
      <img src='<?php echo $this->_tpl_vars['media_info']['media_dir']; 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
' id='media_photo' border='0'>
      </div>
    </div>

        <div id="media_caption" class='media_caption' style='width: <?php if ($this->_tpl_vars['media_info']['media_width'] > 300): 
 echo $this->_tpl_vars['media_info']['media_width']; 
 else: ?>300<?php endif; ?>px;'>
      <div id='title' class='media_title' <?php if ($this->_tpl_vars['media_info']['media_title'] == ""): ?>style='display:none;'<?php endif; ?>><?php if ($this->_tpl_vars['media_info']['media_title'] != ""): 
 echo $this->_tpl_vars['media_info']['media_title']; 
 endif; ?></div>
      <div id='desc' id="media_desc" <?php if ($this->_tpl_vars['media_info']['media_desc'] == ""): ?>style='display:none;'<?php endif; ?>><?php if ($this->_tpl_vars['media_info']['media_desc'] != ""): 
 echo $this->_tpl_vars['media_info']['media_desc']; 
 endif; ?></div>
      <?php ob_start(); 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_parent_url'])) ? $this->_run_mod_handler('replace', true, $_tmp, "[media_parent_id]", $this->_tpl_vars['media_info']['media_parent_id']) : smarty_modifier_replace($_tmp, "[media_parent_id]", $this->_tpl_vars['media_info']['media_parent_id'])); 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('parent_link', ob_get_contents());ob_end_clean(); ?>
      <div id='from'><?php if ($this->_tpl_vars['media_info']['user_id'] != 0): 
 echo sprintf(SELanguage::_get(1216), $this->_tpl_vars['parent_link'], $this->_tpl_vars['media_info']['media_parent_title'], $this->_tpl_vars['url']->url_create('profile',$this->_tpl_vars['media_info']['user']->user_info['user_username']), $this->_tpl_vars['media_info']['user']->user_displayname); 
 else: 
 echo sprintf(SELanguage::_get(1217), $this->_tpl_vars['parent_link'], $this->_tpl_vars['media_info']['media_parent_title']); 
 endif; ?></div>
      <div id='media_tags' style='display: none; margin-top: 10px;'><?php echo SELanguage::_get(1218); ?></div>
      <?php if ($this->_tpl_vars['allowed_to_tag']): ?>
        <a href='javascript:void(0);' onClick="SocialEngine.MediaTag.addTag();"><?php echo SELanguage::_get(1212); ?></a>
      <?php endif; ?>
      <div class='media_date'>
      <span id="posted_date">
        <?php $this->assign('uploaddate', $this->_tpl_vars['datetime']->time_since($this->_tpl_vars['media_info']['media_date'])); 
 ob_start(); 
 echo sprintf(SELanguage::_get($this->_tpl_vars['uploaddate'][0]), $this->_tpl_vars['uploaddate'][1]); 
 $this->_smarty_vars['capture']['default'] = ob_get_contents();  $this->assign('uploaddate_text', ob_get_contents());ob_end_clean(); ?>
        <?php echo sprintf(SELanguage::_get(1219), $this->_tpl_vars['uploaddate_text']); ?> 
        </span>
        -
        <a href="javascript:TB_show('<?php echo SELanguage::_get(1220); ?>', '#TB_inline?height=400&width=400&inlineId=sharethis', '', '../images/trans.gif');"><?php echo SELanguage::_get(1220); ?></a>
        <?php if ($this->_tpl_vars['user']->user_exists): ?>-<?php endif; ?> 
        <a  id="report_content" <?php if (! $this->_tpl_vars['user']->user_exists): ?>style='display:none;'<?php endif; ?> href="javascript:TB_show('<?php echo SELanguage::_get(1221); ?>', 'user_report.php?return_url=<?php echo ((is_array($_tmp=$this->_tpl_vars['url']->url_current())) ? $this->_run_mod_handler('escape', true, $_tmp, 'url') : smarty_modifier_escape($_tmp, 'url')); ?>
&TB_iframe=true&height=300&width=450', '', './images/trans.gif');"><?php echo SELanguage::_get(1221); ?></a>
      </div>
    </div>
  </td>
  </tr>
  </table>
</div>


<div style='display: none;' id='sharethis'>
  <div style='margin: 10px 0px 10px 0px;'><?php echo SELanguage::_get(1222); ?></div>
  <div style='margin: 10px 0px 10px 0px; font-weight: bold;'><?php echo SELanguage::_get(1223); ?></div>
  <textarea id="direct_link" readonly='readonly' onClick='this.select()' class='text' rows='2' cols='30' style='width: 95%; font-size: 7pt;'><?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
</textarea>
  <div style='margin: 10px 0px 10px 0px; font-weight: bold;'><?php echo SELanguage::_get(1224); ?></div>
  <textarea id="embedded_image" readonly='readonly' onClick='this.select()' class='text' rows='2' cols='30' style='width: 95%; font-size: 7pt;'><a href='<?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
'><img src='<?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
' border='0'></a></textarea>
  <div style='margin: 10px 0px 10px 0px; font-weight: bold;'><?php echo SELanguage::_get(1225); ?></div>
  <textarea id="text_link" readonly='readonly' onClick='this.select()' class='text' rows='2' cols='30' style='width: 95%; font-size: 7pt;'><a href='<?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
'><?php if ($this->_tpl_vars['media_info']['media_title'] != ""): 
 echo $this->_tpl_vars['media_info']['media_title']; 
 else: 
 echo SELanguage::_get(589); 
 endif; ?></a></textarea>
  <div style='margin: 10px 0px 10px 0px; font-weight: bold;'><?php echo SELanguage::_get(1226); ?></div>
  <textarea id="ubb_code" readonly='readonly' onClick='this.select()' class='text' rows='2' cols='30' style='width: 95%; font-size: 7pt;'>[url=<?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
][img]<?php echo $this->_tpl_vars['url']->url_base; 
 echo ((is_array($_tmp=$this->_tpl_vars['media_info']['media_dir'])) ? $this->_run_mod_handler('replace', true, $_tmp, "./", "") : smarty_modifier_replace($_tmp, "./", "")); 
 echo $this->_tpl_vars['media_info']['media_id']; ?>
.<?php echo $this->_tpl_vars['media_info']['media_ext']; ?>
[/img][/url]</textarea>
  <div style='margin-top: 10px;'>
    <input type='button' class='button' value='<?php echo SELanguage::_get(1227); ?>' onClick='parent.TB_remove();'>
  </div>
</div>


<?php 
$javascript_lang_import_list = SELanguage::_javascript_redundancy_filter(array(39,1212,1213,1214,1215,1228));
$javascript_lang_import_first = TRUE;
if( is_array($javascript_lang_import_list) && !empty($javascript_lang_import_list) )
{
  echo "\n<script type='text/javascript'>\n<!--\n";
  echo "SocialEngine.Language.Import({\n";
  foreach( $javascript_lang_import_list as $javascript_import_id )
  {
    if( !$javascript_lang_import_first ) echo ",\n";
    echo "  ".$javascript_import_id." : '".addslashes(SE_Language::_get($javascript_import_id))."'";
    $javascript_lang_import_first = FALSE;
  }
  echo "\n});\n//-->\n</script>\n";
}
 ?>
      
<script type="text/javascript">
        
  SocialEngine.MediaTag = new SocialEngineAPI.Tags({
      'canTag' : <?php if ($this->_tpl_vars['allowed_to_tag']): ?>true<?php else: ?>false<?php endif; ?>,

      'type' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
',
      'media_id' : <?php echo $this->_tpl_vars['media_info']['media_id']; ?>
,
      'media_dir' : '<?php echo $this->_tpl_vars['media_info']['media_dir']; ?>
',

      'object_owner' : <?php if ($this->_tpl_vars['media_info']['user_id'] != 0): ?>false<?php else: ?>'<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
'<?php endif; ?>,
      'object_owner_id' : <?php if ($this->_tpl_vars['media_info']['user_id'] != 0): ?>false<?php else: 
 echo $this->_tpl_vars['media_info']['media_parent_id']; 
 endif; ?>

    });
        
    SocialEngine.RegisterModule(SocialEngine.MediaTag);
       
    <?php unset($this->_sections['tag_loop']);
$this->_sections['tag_loop']['name'] = 'tag_loop';
$this->_sections['tag_loop']['loop'] = is_array($_loop=$this->_tpl_vars['tags']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['tag_loop']['show'] = true;
$this->_sections['tag_loop']['max'] = $this->_sections['tag_loop']['loop'];
$this->_sections['tag_loop']['step'] = 1;
$this->_sections['tag_loop']['start'] = $this->_sections['tag_loop']['step'] > 0 ? 0 : $this->_sections['tag_loop']['loop']-1;
if ($this->_sections['tag_loop']['show']) {
    $this->_sections['tag_loop']['total'] = $this->_sections['tag_loop']['loop'];
    if ($this->_sections['tag_loop']['total'] == 0)
        $this->_sections['tag_loop']['show'] = false;
} else
    $this->_sections['tag_loop']['total'] = 0;
if ($this->_sections['tag_loop']['show']):

            for ($this->_sections['tag_loop']['index'] = $this->_sections['tag_loop']['start'], $this->_sections['tag_loop']['iteration'] = 1;
                 $this->_sections['tag_loop']['iteration'] <= $this->_sections['tag_loop']['total'];
                 $this->_sections['tag_loop']['index'] += $this->_sections['tag_loop']['step'], $this->_sections['tag_loop']['iteration']++):
$this->_sections['tag_loop']['rownum'] = $this->_sections['tag_loop']['iteration'];
$this->_sections['tag_loop']['index_prev'] = $this->_sections['tag_loop']['index'] - $this->_sections['tag_loop']['step'];
$this->_sections['tag_loop']['index_next'] = $this->_sections['tag_loop']['index'] + $this->_sections['tag_loop']['step'];
$this->_sections['tag_loop']['first']      = ($this->_sections['tag_loop']['iteration'] == 1);
$this->_sections['tag_loop']['last']       = ($this->_sections['tag_loop']['iteration'] == $this->_sections['tag_loop']['total']);
?>
      insertTag('<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_id']; ?>
', '<?php if ($this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['tagged_user']->user_exists): 
 echo $this->_tpl_vars['url']->url_create('profile',$this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['tagged_user']->user_info['user_username']); 
 endif; ?>', '<?php if ($this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['tag_user']->user_exists): 
 echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['tagged_user']->user_displayname; 
 else: 
 echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_text']; 
 endif; ?>', '<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_x']; ?>
', '<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_y']; ?>
', '<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_width']; ?>
', '<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['mediatag_height']; ?>
', '<?php echo $this->_tpl_vars['tags'][$this->_sections['tag_loop']['index']]['tagged_user']->user_info['user_username']; ?>
')
    <?php endfor; endif; ?>

    // Backwards
    function insertTag(tag_id, tag_link, tag_text, tag_x, tag_y, tag_width, tag_height, tagged_user)
    {
      SocialEngine.MediaTag.insertTag(tag_id, tag_link, tag_text, tag_x, tag_y, tag_width, tag_height, tagged_user);
    }

  </script>

</div>


<table  cellpadding='0' cellspacing='0' align='center' style='margin-top:15px; width:632px;'>
<tr>
<td  style="background:#F2F2F2; border:1px solid #DDDDDD; padding:5px">
  <div style="float:left"><?php if ($this->_tpl_vars['media_count'] > 7): ?><a href="javascript:void();" onClick="javascript:updateCarousel('prev', 0, <?php echo $this->_tpl_vars['page_owner']->user_info['user_id']; ?>
, true); event.returnValue=false; return false"><img src="images/icons/media_moveleft.gif" border='0' onMouseOver="this.src='images/icons/media_moveleft2.gif';" onMouseOut="this.src='images/icons/media_moveleft.gif';"></a><?php endif; ?></div>
   <div id='album_carousel' style="width: 562px; text-align: center; float:left; margin-left:15px">   
  
  </div>
  <div style="float:right"><?php if ($this->_tpl_vars['media_count'] > 7): ?><a href="javascript:void();" onClick="javascript:updateCarousel('next', 0, <?php echo $this->_tpl_vars['page_owner']->user_info['user_id']; ?>
, true); event.returnValue=false; return false"><img src="images/icons/media_moveright.gif" border='0' onMouseOver="this.src='./images/icons/media_moveright2.gif';" onMouseOut="this.src='./images/icons/media_moveright.gif';"></a><?php endif; ?></div>
  <span id="carousel_page_num" style="display: none">0</span>
  <span id="carousel_count" style="display: none"><?php echo $this->_tpl_vars['media_count_pages']; ?>
</span>

</td>
</tr>
</table>


<div style='width: <?php echo $this->_tpl_vars['menu_width']; ?>
px; margin-left: auto; margin-right: auto;'>


<?php echo '
<script type=\'text/javascript\'>
<!--

  var visiblePhotos = 7;
  var current_id = 0;
  var myFx;

  window.addEvent(\'domready\', function() {
 //   myFx = new Fx.Scroll(\'album_carousel\');
    current_id = parseInt('; 
 echo smarty_function_math(array('equation' => "x-2",'x' => $this->_tpl_vars['current_index']), $this);
 echo ');
 
   // myFx.set(position.x, position.y);
    updateCarousel(\'next\', 0, '; 
 echo $this->_tpl_vars['page_owner']->user_info['user_id']; 
 echo ', true )     ;        
    block_val = false;  
  });


  function moveLeft() {
    if($(\'thumb\'+(current_id-1))) {
      myFx.toElement(\'thumb\'+(current_id-1));
      myFx.toLeft();
      current_id = parseInt(current_id-1);
    }
  }

  function moveRight() {
    if($(\'thumb\'+(current_id+visiblePhotos))) {
      myFx.toElement(\'thumb\'+(current_id+1));
      myFx.toRight();
      current_id = parseInt(current_id+1);
    }
  }

//-->
</script>
'; ?>


<br>


<div id="post_comment_box" style='margin-left: auto; margin-right: auto;'>

    <div id="<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
media_<?php echo $this->_tpl_vars['media_info']['media_id']; ?>
_postcomment"></div>
  <div id="<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
media_<?php echo $this->_tpl_vars['media_info']['media_id']; ?>
_comments" style='margin-left: auto; margin-right: auto;'></div>
      
  <?php 
$javascript_lang_import_list = SELanguage::_javascript_redundancy_filter(array(39,155,175,182,183,184,185,187,784,787,829,830,831,832,833,834,835,854,856,891,1025,1026,1032,1034,1071));
$javascript_lang_import_first = TRUE;
if( is_array($javascript_lang_import_list) && !empty($javascript_lang_import_list) )
{
  echo "\n<script type='text/javascript'>\n<!--\n";
  echo "SocialEngine.Language.Import({\n";
  foreach( $javascript_lang_import_list as $javascript_import_id )
  {
    if( !$javascript_lang_import_first ) echo ",\n";
    echo "  ".$javascript_import_id." : '".addslashes(SE_Language::_get($javascript_import_id))."'";
    $javascript_lang_import_first = FALSE;
  }
  echo "\n});\n//-->\n</script>\n";
}
 ?>
      
  <script type="text/javascript">
        
    SocialEngine.MediaComments = new SocialEngineAPI.Comments({
      'canComment' : <?php if ($this->_tpl_vars['allowed_to_comment']): ?>true<?php else: ?>false<?php endif; ?>,
      'commentHTML' : '<?php echo ((is_array($_tmp=$this->_tpl_vars['setting']['setting_comment_html'])) ? $this->_run_mod_handler('replace', true, $_tmp, ",", ", ") : smarty_modifier_replace($_tmp, ",", ", ")); ?>
',
      'commentCode' : <?php if ($this->_tpl_vars['setting']['setting_comment_code']): ?>true<?php else: ?>false<?php endif; ?>,

      'type' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
media',
      'typeIdentifier' : '<?php echo $this->_tpl_vars['media_info']['type_id']; ?>
',
      'typeID' : <?php echo $this->_tpl_vars['media_info']['media_id']; ?>
,
          
      'typeTab' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
media',
      'typeCol' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
media',
      'typeTabParent' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
albums',
      'typeColParent' : '<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
album',
      'typeChild' : true,

      'object_owner' : <?php if ($this->_tpl_vars['media_info']['user_id'] != 0): ?>false<?php else: ?>'<?php echo $this->_tpl_vars['media_info']['type_prefix']; ?>
'<?php endif; ?>,
      'object_owner_id' : <?php if ($this->_tpl_vars['media_info']['user_id'] != 0): ?>false<?php else: 
 echo $this->_tpl_vars['media_info']['media_parent_id']; 
 endif; ?>,
          
      'initialTotal' : <?php echo ((is_array($_tmp=@$this->_tpl_vars['total_comments'])) ? $this->_run_mod_handler('default', true, $_tmp, 0) : smarty_modifier_default($_tmp, 0)); ?>

    });
        
    SocialEngine.RegisterModule(SocialEngine.MediaComments);
       
    // Backwards
    function addComment(is_error, comment_body, comment_date)
    {
      SocialEngine.MediaComments.addComment(is_error, comment_body, comment_date);
    }
        
    function getComments(direction)
    {
      SocialEngine.MediaComments.getComments(direction);
    }

  </script>

</div>




</div>



<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => 'footer.tpl', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>